﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;
using System.Data.Entity;

namespace VolunteerWebsite.Models
{
    public class News
    {
        [Display(Name = "ID")]
        public int ID { get; set; }
        [Display(Name = "新闻标题")]
        public string Title { get; set; }
        [Display(Name = "发布时间")]
        public DateTime ReleaseDate { get; set; }
        [Display(Name = "作者")]
        public string Author { get; set; }
        [Display(Name = "新闻正文")]
        public string Context { get; set; }
    }
    public class NewsDBContext : DbContext
    {
        public DbSet<News> NewsContext { get; set; }
    }
}